import { S } from '../../s';
import { IPSAppDEUIActionGroup } from '../../app/dataentity/ipsapp-deuiaction-group';
import { IPSDEUIActionGroup } from './ipsdeuiaction-group';
import { IPSUIActionGroupDetail } from '../../view/ipsuiaction-group-detail';
import { PSModelObjectImpl } from '../../psmodel-object-impl';

export class PSDEUIActionGroupImpl
  extends PSModelObjectImpl
  implements IPSDEUIActionGroup, IPSAppDEUIActionGroup
{
  get codeName(): string {
    return this.M.codeName;
  }

  get groupTag(): string {
    return this.M.groupTag;
  }

  get groupTag2(): string {
    return this.M.groupTag2;
  }

  get groupTag3(): string {
    return this.M.groupTag3;
  }

  get groupTag4(): string {
    return this.M.groupTag4;
  }

  protected psuiactiongroupdetails: IPSUIActionGroupDetail[];
  getPSUIActionGroupDetails(): IPSUIActionGroupDetail[] | null {
    return (
      this.psuiactiongroupdetails ||
      (this.psuiactiongroupdetails = this.fillChildListModel(
        this.M.getPSUIActionGroupDetails,
        S._20d,
      ) as IPSUIActionGroupDetail[])
    );
  }

  findPSUIActionGroupDetail(objKey: any): IPSUIActionGroupDetail | null {
    return this.getPSModel5(
      S._20d,
      this.getPSUIActionGroupDetails(),
      objKey,
    ) as IPSUIActionGroupDetail;
  }

  get uniqueTag(): string {
    return this.M.uniqueTag;
  }
  get cls(): string {
    return 'PSDEUIActionGroupImpl';
  }
  instanceof(cls: string): boolean {
    if (cls == S._20e || cls == S._20f || cls == S._210) return true;
    return super.instanceof(cls);
  }
}
